package com.aurora.blog.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.aurora.blog.mapper.BlogLikesMapper;
import com.aurora.blog.domain.BlogLikes;
import com.aurora.blog.service.IBlogLikesService;

/**
 * 点赞Service业务层处理
 * 
 * @author aurora
 * @date 2024-06-04
 */
@Service
public class BlogLikesServiceImpl implements IBlogLikesService 
{
    @Autowired
    private BlogLikesMapper blogLikesMapper;

    /**
     * 查询点赞
     * 
     * @param likeId 点赞主键
     * @return 点赞
     */
    @Override
    public BlogLikes selectBlogLikesByLikeId(Long likeId)
    {
        return blogLikesMapper.selectBlogLikesByLikeId(likeId);
    }

    /**
     * 查询点赞列表
     * 
     * @param blogLikes 点赞
     * @return 点赞
     */
    @Override
    public List<BlogLikes> selectBlogLikesList(BlogLikes blogLikes)
    {
        return blogLikesMapper.selectBlogLikesList(blogLikes);
    }

    /**
     * 新增点赞
     * 
     * @param blogLikes 点赞
     * @return 结果
     */
    @Override
    public int insertBlogLikes(BlogLikes blogLikes)
    {
        return blogLikesMapper.insertBlogLikes(blogLikes);
    }

    /**
     * 修改点赞
     * 
     * @param blogLikes 点赞
     * @return 结果
     */
    @Override
    public int updateBlogLikes(BlogLikes blogLikes)
    {
        return blogLikesMapper.updateBlogLikes(blogLikes);
    }

    /**
     * 批量删除点赞
     * 
     * @param likeIds 需要删除的点赞主键
     * @return 结果
     */
    @Override
    public int deleteBlogLikesByLikeIds(Long[] likeIds)
    {
        return blogLikesMapper.deleteBlogLikesByLikeIds(likeIds);
    }

    /**
     * 删除点赞信息
     * 
     * @param likeId 点赞主键
     * @return 结果
     */
    @Override
    public int deleteBlogLikesByLikeId(Long likeId)
    {
        return blogLikesMapper.deleteBlogLikesByLikeId(likeId);
    }
}
